Part Number Hot Search : 
2SC57 BH7673 UGSP15D EXE8602 160808 15KPA78A FS020551 BYT53C
Product Description
Full Text Search
 

To Download LPC1111FHN33 Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  an10955 full-duplex software uart for lpc111x and lpc13xx rev. 1 ? 13 july 2010 application note document information info content keywords lpc111x, lpc13xx, uart, software abstract this application note illustrates how software running on an lpc111x or lpc13xx processor can implement the behavior of a standard universal asynchronous receiver/transmitter (uart)
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 2 of 11 contact information for additional information, please visit: http://www.nxp.com for sales office addresses, please send an email to: salesaddresses@nxp.com revision history rev date description 1 20100713 initial version.
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx 1. introduction the lpc111x and lpc13xx families of microcontrollers offer a wide range of communication interfaces. each microcontroller contains one on-chip universal asynchronous receiver/transmitter (uart). however, some applications require more uarts than are available on the device. while the addition of an external stand-alone uart ic could be used in some of these situations, software based uarts result in reduced bom costs and take up no additional space on the pcb. this allows designers to meet their ever increasing miniaturizat ion requirements and ever decreasing cost targets. this application note describes one possible implementation of the full-duplex software uart. this software uart for lpc111x and lpc13xx is migrated from the lpc2000 software uart. for the principle of software uart implementation, please refer to an10689 ? lpc2000 software uart for details. this application note made use of the embedded artists? lpcxpresso 1114 rev a and lpcxpresso base board rev a evaluation kits with code red lpcxpresso 3.3.4. care should be taken to make sure that the proper jumper configuration on the base board is in place, in particular that the thermal sensor is not connected to p1.5 nor is the potentiometer connected to p0.11 be aware that the example software packages are not optimized. the additional space required by adding the software uart functio nality to an existing design can be as low as 1 kb when additional care is taken to optimize the code density. if full-duplex operation is not required by a particular application, code size can be further reduced by trimming the unused features of the uart. 2. implementation this solution relies on a general purpose 32-bit timer and its ability to toggle a dedicated pin while simultaneously monitoring the stat e of another pin. while the capture and toggle functions of the timer are used, the receive routine also uses an additional match register of the timer. each ti mer has four match registers; table 1 indicates their allocation. in this application note, timer32_0 was used. see table 2 for the transfer format used in the example code. table 1. m atch register usage timer mrn function mr0 rx mr1 rx mr2 available to user mr3 tx the software implementation has variable depth fifos enabling buffering for both transmission and reception. it should be noted that the uart baud rate, as well as transmitter and receiver fifo depth, are c onfigured during the compilation process and thus cannot be changed at runtime. an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 3 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx table 2. u art transfer format parameter value start bits 1 data bits 8 stop bits 1 parity none the demo source code takes adv antage of the pin compat ibility between the lpc111x and lpc13xx and therefore requires minimal modification to change between target platforms. table 3 lists the functions of the pins us ed in the demo. both of the targeted evaluation modules used in this application note are equipped with hardware to convert the peripheral uart signals to either rs-232 or usb. the software uart pins must be externally connected to these signals in order to communicate with a host pc. because the pins of the lpc111x/lpc13xx default to using configurable pull-up resistors p1.6 and p1.7 should be set to inactive mode to prevent contention with the software uart signals. table 3. pin functions pin number configuration description p0.11 ct32b0_mat3 software tx p1.5 ct32b0_cap0 software rx p1.6 gpio (inactive) rs-232 driver rx p1.7 gpio (inactive) rs-232 driver tx p1.11 output call indicator (active low) p3.0 output tx_pro indicator (active low) p3.1 output int ct32b0 interrupt indicator (active low) p3.2 output int_tx tx inte rrupt indicator (active low) p3.3 output int_rx rx inte rrupt indicator (active low) 3. software environment included with this application note are several versions of the example software project. they have been tested in the environments listed in table 4 . default (i.e., without optimization) sizes for the example project are listed in table 5 . table 4. tool versions used tool version lpc1114 pcb lpc1343 pcb lpcxpresso v3.3.4 lpcxpresso lpc1114 rev. a, lpcxpresso base board rev. a lpcxpresso lpc1343 rev a. lpcxpresso base board rev. a iar c/c++ compiler for arm 5.50.0.31878 lpc1114-sk re v. b lpc1343-sk rev. b keil c/c++ compiler v4.0.0.728 lpc1114-sk rev. b lpc1343-sk rev. b an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 4 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx table 5. estimated build size tool device text (bytes) lpcxpresso lpc1114 3632 lpcxpresso lpc1343 5236 iar lpc1114 3636 iar lpc1343 3710 keil lpc1114 3796 keil lpc1343 4216 4. hardware configuration ? iar lpc1114 sk an example wiring connection can be seen in fig 1 . please be aware that the jumpers connecting p0.11 to p1.7 interfere with the 20 pin standard connector for debugging. this does not affect debugging via the on board jlink, however, it requires external debuggers such as the keil ulink2 use the 10 pin swd header. fig 1. iar lpc1114 sk jumpers p0.11 p1.7 p1.5 p1.6 serial port swd connector rs-232 transceiver lpc111x/13xx an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 5 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx 5. hardware configuration ? lpc1114 lpcxpresso fig 2 illustrates how to connect the software uart signals to the usb translation ic. fig 2. lpc1114 lpcxpresso and base board jumpers p0.11 p1.7 uart usb ic usb p1.5 p1.6 lpc111x / 13xx 6. operation the demo code for lpc13xx family was tested under several conditions: in a system running an external 12 mhz crystal without the use of a system pll, as well as in systems using the pll to generate 24 mhz, 60 mhz and 72 mhz system clocks. the lpc111x family was tested in a system running an external 12 mhz crystal as well as systems using the pll to generate 24 mhz and 48 mhz system clocks. it should be noted that the uart?s baud rate is dependent upon the system clock frequency. therefore systems using a cloc k frequency which differ from the example code?s 48 mhz/72 mhz must update the bit_leng th definitions in the project?s source code. for example, in a 12 mhz system tr ansferring serial data at 9600 bit/s, the bit_length is equal to 12000000/9600 = 1250. if the system clock is changed to 48 mhz, bit_length should be changed to 48000000/9600 = 5000. the demo application will initially prompt t he user with a message, and will then enter a perpetual loop in which received characters are echoed back to the user. this is illustrated in fig 3 . an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 6 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx fig 3. example output 7. results the oscilloscope screenshots of signal li nes could be helpful when debugging. since they are similar to the lpc2000 software uart, please refer to an10689 for details. based on the demo application, the baud rates in table 6 and table 7 were determined to be the maximum reliable speed for each system clock frequency listed. table 6. l pc111x test results system clock (mhz) max. transmit (bit/s) max. receive (bit/s) 12 9600 4800 24 38400 9600 48 57600 19200 table 7. l pc13xx test results system clock (mhz) max. transmit (bit/s) max. receive (bit/s) 12 9600 4800 24 38400 9600 60 115200 19200 72 115200 38400 8. conclusion despite the lpc11xx/lpc13xx part fam ilies being equipped with a single uart peripheral, with this example designers can augment their products with an additional software uart channel. by using the softw are based implementation no additional ics will need to be added to the pcb, thus saving space and reducing the cost of manufacturing. an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 7 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 8 of 11 9. legal information 9.1 definitions draft ? the document is a draft version only. the content is still under internal review and subject to formal approval, which may result in modifications or additions. nxp semiconductors does not give any representations or warranties as to the accuracy or completeness of information included herein and shall have no liability for the consequences of use of such information. 9.2 disclaimers limited warranty and liability ? information in this document is believed to be accurate and reliable. however, nxp semiconductors does not give any representations or warranties, expressed or implied, as to the accuracy or completeness of such informatio n and shall have no liability for the consequences of use of such information. in no event shall nxp semiconductors be liable for any indirect, incidental, punitive, special or consequential damages (including - without limitation - lost profits, lost savings, business inte rruption, costs related to the removal or replacement of any products or re work charges) whether or not such damages are based on tort (including negligence), warranty, breach of contract or any other legal theory. notwithstanding any damages that cu stomer might incur for any reason whatsoever, nxp semiconductors? aggregate and cumulative liability towards customer for the products described herein shall be limited in accordance with the terms and condi tions of commercial sale of nxp semiconductors. right to make changes ? nxp semiconductors reserves the right to make changes to information published in this document, including without limitation specifications and product de scriptions, at any time and without notice. this document supersedes and replaces all information supplied prior to the publication hereof. suitability for use ? nxp semiconductors produ cts are not designed, authorized or warranted to be suitable for use in life support, life-critical or safety-critical systems or equipment, nor in applications where failure or malfunction of an nxp semiconductors product can reasonably be expected to result in personal injury, death or severe property or environmental damage. nxp semiconductors accepts no liability for inclusion and/or use of nxp semiconductors products in such equipment or applications and therefore such inclusion and/or use is at the customer?s own risk. applications ? applications that are described herein for any of these products are for illustrative purposes only. nxp semiconductors makes no representation or warranty that such applications will be suitable for the specified use without further testing or modification. customers are responsible for the design and operation of their applications and products using nxp semiconductors products, and nxp semiconductors accepts no liability for any assistance with applications or customer product design. it is custom er?s sole responsibility to determine whether the nxp semiconductors product is suitable and fit for the customer?s applications and products planned, as well as for the planned application and use of customer?s third party customer(s). customers should provide appropriate design and operating safeguards to minimize the risks associated with their applications and products. nxp semiconductors does not accept any liability related to any default, damage, costs or problem which is bas ed on any weakness or default in the customer?s applications or products, or the application or use by customer?s third party customer(s). customer is responsible for doing all necessary testing for the customer?s applic ations and products using nxp semiconductors products in order to av oid a default of the applications and the products or of the application or use by customer?s third party customer(s). nxp does not accept any liability in this respect. export control ? this document as well as the item(s) described herein may be subject to export control regulations. export might require a prior authorization from national authorities. 9.3 trademarks notice: all referenced brands, product names, service names and trademarks are property of their respective owners.
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx 10. list of figures fig 1. iar lpc1114 sk jumpers .................................5 fig 2. lpc1114 lpcxpresso and base board jumpers ..........................................................................6 fig 3. example output .................................................7 an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 9 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx 11. list of tables table 1. match register usage ........................................3 table 2. uart transfer format ........................................4 table 3. pin functions .....................................................4 table 4. tool versions used ............................................4 table 5. estimated build size ..........................................5 table 6. lpc111x test results ........................................7 table 7. lpc13xx test results ........................................7 an10955 all information provided in this document is subject to legal disclaimers. ? nxp b.v. 2010. all rights reserved. application note rev. 1 ? 13 july 2010 10 of 11
nxp semiconductors an10955 full-duplex software uart for lpc111x and lpc13xx please be aware that important notices concerning this document and the product(s) described herein, have been included in the section 'legal information'. ? nxp b.v. 2010. all rights reserved. for more information, visit: http://www.nxp.com for sales office addresses, please send an email to: salesaddresses@nxp.com date of release: 13 july 2010 document identifier: an10955 12. contents 1. introduction .........................................................3 2. implementation ....................................................3 3. software environment .........................................4 4. hardware configuration ? iar lpc1114 sk ......5 5. hardware configuration ? lpc1114 lpcxpresso .........................................................6 6. operation .............................................................6 7. results .................................................................7 8. conclusion ...........................................................7 9. legal information ................................................8 9.1 definitions ..........................................................8 9.2 disclaimers .........................................................8 9.3 trademarks ........................................................8 10. list of figures .......................................................9 11. list of tables ......................................................10 12. contents .............................................................11


▲Up To Search▲   

 
Price & Availability of LPC1111FHN33

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X